public class ManKind {
    protected int sex;
    protected int salary;

    // 构造器
    public ManKind(int sex, int salary) {
        this.sex = sex;
        this.salary = salary;
    }

    // 方法：判断性别
    public void manOrWoman() {
        if (sex == 1) {
            System.out.println("man");
        } else if (sex == 0) {
            System.out.println("woman");
        } else {
            System.out.println("Unknown sex");
        }
    }

    // 方法：判断是否有工作
    public void employeed() {
        if (salary == 0) {
            System.out.println("no job");
        } else {
            System.out.println("job");
        }
    }
}
